//
//  OfferDetails.m
//  MyOWNUITableView
//
//  Created by Jordy Heemskerk on 19-04-10.
//  Copyright 2010 __MyCompanyName__. All rights reserved.
//

#import "OfferDetails.h"
#import "Product.h"


@implementation OfferDetails
@synthesize price;
@synthesize oldprice;
@synthesize shop;
@synthesize description;
@synthesize image;
@synthesize product;

// Implement viewDidLoad to do additional setup after loading the view, typically from a nib.
- (void)viewDidLoad {
    [super viewDidLoad];
	
	[self setTitle:[product name]];
	
	
	//[image setContentMode:UIViewContentModeScaleAspectFill];
	[description setText:[product description]];
	[shop setText:[product shop]];
	[price setText:[NSString stringWithFormat:@"\u20AC %1.2f",[product.price doubleValue]]];
	[oldprice setText:[NSString stringWithFormat:@"\u20AC %1.2f",[product.oldprice doubleValue]]];
	[image setImage:[product image]];
	
}

- (void)didReceiveMemoryWarning {
	// Releases the view if it doesn't have a superview.
    [super didReceiveMemoryWarning];
	
	// Release any cached data, images, etc that aren't in use.
}

- (void)viewDidUnload {
	// Release any retained subviews of the main view.
	// e.g. self.myOutlet = nil;
}


- (void)dealloc {
    [super dealloc];
}


@end
